<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>JS体验</title>
</head>
<body>

<script>
    // JS代码 打印5次Hello World
    for (var i = 0; i < 5; i++) {
        document.write("Hello World " + i + "<br/>");
    }
</script>

<!--onclick: 当按钮被点击了会执行里面的代码-->
<input type="button" value="前进" onclick="history.forward()"/><br/>
<input type="button" value="后退" onclick="history.back()"/><br/>
</body>
</html>